package beer.coder.awesome.sboot.system.health.controller;

import beer.coder.awesome.sboot.system.health.entity.MonitorData;
import beer.coder.awesome.sboot.system.health.service.MonitorService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/health")
public class MonitorController {
    @Autowired
    MonitorService service;

    @GetMapping("/")
    public MonitorData retrieveMonitorData() {
        return service.retrieveMonitorData();
    }
}
